package com.jk.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

/**
 * @ClassName InhabitantBean
 * @Descripttion TODO 居民表的实体类
 * @Author DELL
 * @Date 2022/10/14 11:22
 * @Version 0.001
 */
@Data
@TableName("inhabitant")
@Document(indexName = "inhabitant")
public class InhabitantBean {

    //    id	int
    @Id
    @TableId(type = IdType.AUTO)
    @Field(value = "id",type = FieldType.Integer)
    private Integer id;//编号
//    name	varchar
    @Field(value = "name",type = FieldType.Text,analyzer = "ik_max_word")
    private String  name;//姓名
//    id_entity	varchar
    @Field(value = "id_entity",type = FieldType.Text)
    private String  id_entity;//身份证号

    @Field(value = "age",type = FieldType.Integer)
    private Integer age;//年龄
//    phone	varchar
    @Field(value = "phone",type = FieldType.Text)
    private String  phone;//手机号
//    state	int
    @Field(value = "state",type = FieldType.Integer)
    private Integer state;//服务状态 1.待审核 2.待服务 3.以驳回
//    service	int
    @Field(value = "service",type = FieldType.Integer)
    private Integer service;//服务包  1.0-6岁儿童服务包 2. .慢性病护理包
//    project	int
    @Field(value = "project",type = FieldType.Integer)
    private Integer project;//服务项目  1.高血压随访
//    application_time	date
    @Field(value = "application_time",type = FieldType.Text)
    private String  application_time;//申请时间
//    doctor_team	int
    @Field(value = "doctor_team",type = FieldType.Integer)
    private Integer doctor_team;//医生团队 1.王皓团队  2.胡曼团队  3.李维团队
//    doctor	varchar
    @Field(value = "doctor",type = FieldType.Text)
    private String  doctor;//医生
//    mechanism	int
    @Field(value = "mechanism",type = FieldType.Integer)
    private Integer mechanism;//签约机构  1.罗西社区服务中心 2.天明社区服务中心 3.民进社区服务中心
//    signing_status	int
    @Field(value = "signing_status",type = FieldType.Integer)
    private Integer signing_status;//签约状态 1.签约中  以签约
//    residentlabel	int
    @Field(value = "residentlabel",type = FieldType.Integer)
    private Integer residentlabel;//居民标签  1.高血压  2.冠心病 3高血糖
//    current_residence	varchar
    @Field(value = "current_residence",type = FieldType.Text)
    private String  current_residence;//现居地
//    login_password	varchar
    @Field(value = "login_password",type = FieldType.Text)
    private String  login_password;//登录密码
//    administrative_division	varchar
    @Field(value = "administrative_division",type = FieldType.Text)
    private String  administrative_division;//行政区划
////    sex	varchar
    @Field(value = "sex",type = FieldType.Text)
    private String  sex;//性别
////    dateOfBirth	date
    @Field(value = "dateOfBirth",type = FieldType.Text)
    private String  dateOfBirth;//出生日期
////    native_place	varchar
    @Field(value = "native_place",type = FieldType.Text)
    private String  native_place;//籍贯
////    nation	varchar
    @Field(value = "nation",type = FieldType.Text)
    private String  nation;//民族
////    degreeof_education	varchar
    @Field(value = "degreeof_education",type = FieldType.Text)
    private String  degreeof_education;//文化程度
////    marriage	varchar
    @Field(value = "marriage",type = FieldType.Text)
    private String  marriage;//婚姻状况
////    occupation	varchar
    @Field(value = "occupation",type = FieldType.Text)
    private String  occupation;//职业
////    company	varchar
    @Field(value = "company",type = FieldType.Text)
    private String  company;//单位
////    emergency_contact	varchar
    @Field(value = "emergency_contact",type = FieldType.Text)
    private String  emergency_contact;//紧急联系人
////    contact_phone	varchar
    @Field(value = "contact_phone",type = FieldType.Text)
    private String  contact_phone;//联系人电话
////    household_type	varchar
    @Field(value = "household_type",type = FieldType.Text)
    private String  household_type;//户籍类型
////    cost_type	varchar
    @Field(value = "cost_type",type = FieldType.Text)
    private String  cost_type;//费用类型
////    medical_unit	varchar
    @Field(value = "medical_unit",type = FieldType.Text)
    private String  medical_unit;//医疗单位
////    source	varchar
    @Field(value = "source",type = FieldType.Text)
    private String  source;//来源
////    height	int
    @Field(value = "height",type = FieldType.Integer)
    private Integer height;//身高
////    weight	int
    @Field(value = "weight",type = FieldType.Integer)
    private Integer weight;//体重
////    blood_type	varchar
    @Field(value = "blood_type",type = FieldType.Text)
    private String  blood_type;//血型
////    negative_RH	varchar
    @Field(value = "negative_RH",type = FieldType.Text)
    private String  negative_RH;//RH阴性
////    allergy_history	varchar
    @Field(value = "allergy_history",type = FieldType.Text)
    private String  allergy_history;//过敏史
////    past_history	varchar
    @Field(value = "past_history",type = FieldType.Text)
    private String  past_history;//既往史
////    medical_history	varchar
    @Field(value = "medical_history",type = FieldType.Text)
    private String  medical_history;//就诊史
////    family_history	varchar
    @Field(value = "family_history",type = FieldType.Text)
    private String  family_history;//家族病史

    @Field(value = "pid",type = FieldType.Integer)
    private Integer pid;


    //业务字段
    @TableField(exist = false)
    @JsonIgnore
    private String staterDate;//开始时间
    @TableField(exist = false)
    @JsonIgnore
    private  String  endDate;//结束时间



}
